using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class ParticleSystemPoolNode : MonoBehaviour
{
    public ParticleSystem ParticleSystem;
    
    public Transform ParticleTransform;
    
    public ParticleSystemRenderer ParticleRenderer;

    public ulong LastUseId = 0; // 上次使用时的序列化ID

    public ParticleSystemPoolNode MainChainPre;
    public ParticleSystemPoolNode MainChainNext;

    public ParticleSystemPoolNode SubChainPre;
    public ParticleSystemPoolNode SubChainNext;

    public ParticleSystemPoolNode GetPreNode(bool isMainChain)
    {
        return isMainChain ? MainChainPre : SubChainPre;
    }

    public ParticleSystemPoolNode GetNextNode(bool isMainChain)
    {
        return isMainChain ? MainChainNext : SubChainNext;
    }
}
